// SystemWindowUserControl.cpp
//
// This file implements a UserControl-derived class 
// that is the System Window Control for 
// the TLA data window
/////////////////////////////////////////////////////////////

#include "StdAfx.h"

#using <system.windows.forms.dll>
#using <system.drawing.dll>
#using <system.dll>
#using "TlaNetInterfaces.dll"

#include "systemwindowusercontrol.h"

using namespace System;
using namespace System::Collections;
using namespace System::Windows::Forms;
using namespace Tektronix::LogicAnalyzer::TpiNet;
using namespace Tektronix::LogicAnalyzer::Common;

// Constructs the control.
SystemWindowUserControl::SystemWindowUserControl(void)
{
	InitializeComponent();
}


// Disposes of the control. The plug-in calls this 
// method when it is disposed.
void SystemWindowUserControl::Dispose( bool disposing )
{
	if( disposing )
	{
		if(m_components)
		{
			m_components->Dispose();
		}
	}
	__super::Dispose( disposing );

}


// This method initializes the size and position of controls 
// on the surface of the Control.
void SystemWindowUserControl::InitializeComponent()
{
	m_activateButton = new Button();
	m_userNameBox = new TextBox();
	SuspendLayout();
	// 
	// activateButton
	// 
	m_activateButton->Location = System::Drawing::Point(16, 0);
	m_activateButton->Size = System::Drawing::Size(88, 48);
	m_activateButton->TabIndex = 0;
	m_activateButton->Text = "Show Window";
	// 
	// userNameBox
	// 
	m_userNameBox->Location = System::Drawing::Point(8, 56);
	m_userNameBox->Size = System::Drawing::Size(104, 22);
	m_userNameBox->TabIndex = 1;
	m_userNameBox->Text = S"textBox1";
	// 
	// SystemWindowUserControl
	// 
	Controls->Add(m_userNameBox);
	Controls->Add(m_activateButton);
	Size = System::Drawing::Size(128, 120);
	ResumeLayout(false);
}